package com.study.demo.aop.demo;

import org.springframework.context.ApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;

/**
 * aop代理
 * xml文件配置的方式
 * @author: elvin
 * @time: 2019-04-22 14:32
 * @desc:
 **/
public class Start {
    public static void main(String[] args){
        ApplicationContext ct  = new ClassPathXmlApplicationContext("classpath:demo/aop.xml");
        XiaoMing xm = (XiaoMing) ct.getBean("xiaoMing");
        xm.toSchool("小明");

        System.out.println("====================");
        //((XiaoMing)xm).getName();
        //xm.getName();

        System.out.println("====================");
    }
}
